#pragma warning(disable : 4996)
#include<stdio.h>
#include<string.h>
char* selectionsort(char*[],int);
int find(char[]);
#define YES 1
#define NO 0
#define SIZE 100
int main()
{
	char word[SIZE];
	int a,i;
	gets(word);
	a = find(word);
	char* arr[100] ;
	
	arr[0] = strtok(word, " ");
	for ( i = 1; i < a; i++)
	{
		arr[i] = strtok(NULL, " ");
	}

	selectionsort(arr, a);
	for (i = 0; i < a; i++)
	{
		printf("%s ", arr[i]);
	}
}

int find(char arr[])
{
	int i = 0;
	int flag=0;
	int count = 0;
	for (i = 0; arr[i] != '\0'; i++)
	{
		if (arr[i] == ' ')
		{
			flag = NO;
		}
		else if (flag == NO)
		{
			flag = YES;
			count++;
         }
	}
	return count;
}
char* selectionsort(char*arr[], int size)
{
	int i, j, minidx;
	char *min;
	char* temp;
	for (i = 0; i < size - 1; i++)
	{
		min = arr[i];
		minidx = i;
		for (j = i + 1; j < size; j++)
		{
			if (*arr[j] < *min)
			{
				min = arr[j];
				minidx = j;
            }
		}
		if (*min < *arr[i])
		{
			temp = arr[i];
			arr[i] = min;
			arr[minidx] = temp;
		}
	}
	return(arr[size]);
}